package com.zjm.lock.cyclicbarrier;

import java.util.HashMap;

public class CyclicBarrierUseCase {
    public static void main(String[] args) {
        HashMap<String, String> map = new HashMap();
        map.put("a", "1");
        map.put("b", "2");
        map.put("c", "3");
//        for (Map.Entry<String, String> entry : map.entrySet()) {
//            System.out.println("key: " + entry.getKey() + ", value: " + entry.getValue());
//        }
        for (String key : map.keySet()) {
            System.out.println("key: " + key + ", value: " + map.get(key));
            map.remove(map.get(key));
        }
        System.out.println(map);

    }
}
